/* Animation keyframes for cards */
@keyframes fadeInSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* General Body and Main Container Styles */


.portfolio-container {
    width: 100%;
    max-width: 1200px;
    margin: auto;
    padding: 0 1rem;
}

/* Category Section Styles */
.category-section {
    margin-bottom: 3rem;
}

.category-section h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #fbba1e;
    /* Using one of the user's specified colors */
    margin-bottom: 1.5rem;
    text-align: center;
}

/* Card Grid Layout */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    justify-content: center;
}

/* Card Styles */
.card {
    background-color: #1a1a1a;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;

    /* Initial state for animation */
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInSlideUp 0.8s ease forwards;
}

/* Staggered animation delay */
.card:nth-child(1) {
    animation-delay: 0.2s;
}

.card:nth-child(2) {
    animation-delay: 0.4s;
}

.card:nth-child(3) {
    animation-delay: 0.6s;
}

.card:nth-child(4) {
    animation-delay: 0.8s;
}

.card:nth-child(5) {
    animation-delay: 1.0s;
}

.card:nth-child(6) {
    animation-delay: 1.2s;
}

.card:nth-child(7) {
    animation-delay: 1.4s;
}

.card:nth-child(8) {
    animation-delay: 1.6s;
}

.card:nth-child(9) {
    animation-delay: 1.8s;
}

.card:nth-child(10) {
    animation-delay: 2.0s;
}

.card:nth-child(11) {
    animation-delay: 2.2s;
}

.card:nth-child(12) {
    animation-delay: 2.4s;
}

.card:nth-child(13) {
    animation-delay: 2.6s;
}

.card:nth-child(14) {
    animation-delay: 2.8s;
}

.card:nth-child(15) {
    animation-delay: 3.0s;
}

.card:nth-child(16) {
    animation-delay: 3.2s;
}

.card:nth-child(17) {
    animation-delay: 3.4s;
}

.card:nth-child(18) {
    animation-delay: 3.6s;
}

.card:nth-child(19) {
    animation-delay: 3.8s;
}

.card:nth-child(20) {
    animation-delay: 4.0s;
}

.card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

/* Image Hover Effect */
.image-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    /* 16:9 Aspect Ratio */
    overflow: hidden;
}

.card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.5s ease-in-out;
}

.card-image.hover-image {
    opacity: 0;
}

.card:hover .card-image.main-image {
    opacity: 0;
}

.card:hover .card-image.hover-image {
    opacity: 1;
}

/* Card Content and Specs */
.card-content {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #629A7C;
    /* One of the user's specified colors */
    margin-bottom: 1rem;
}

.card-specs {
    margin-bottom: 1.5rem;
}

.spec-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.spec-item .label {
    font-weight: 600;
    color: #ccc;
    min-width: 120px;
}

.spec-item .value {
    color: #aaa;
    line-height: 1.5;
}

/* Buttons */
.card-buttons {
    display: flex;
    gap: 1rem;
}

.card-buttons .btn {
    flex-grow: 1;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    text-align: center;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.2s ease;
    color: #fff;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn.site-preview {
    background-color: #28a745;
    /* One of the user's specified colors */
}

.btn.site-preview:hover {
    background-color: #218838;
    transform: scale(1.05);
}

.btn.youtube-preview {
    background-color: #ed1f11;
    /* One of the user's specified colors */
}

.btn.youtube-preview:hover {
    background-color: #c82333;
    transform: scale(1.05);
}